﻿using RedisInAction;
using StackExchange.Redis;
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Threading.Tasks;

namespace Demo
{
    class Program
    {
        static void Main(string[] args)
        {
            Init();
            //TestGeneration.TestNO1();
            //TestGeneration.TestNO2();
            //TestGeneration.TestNO3();
            //TestGeneration.TestNO4();
            //TestGeneration.TestNO5();
            //TestBloomFilter.Test1();
            //TestDistributedLock.Test1();
            //Console.WriteLine("--------------------------------------");
            // TestDistributedLock.Test2();
            TestQueue.add();
            Console.ReadKey();
        }


        private static void Init()
        {
            System.Threading.ThreadPool.SetMinThreads(200, 200);
            ConfigurationOptions config = new ConfigurationOptions();
            config.EndPoints.Add("10.10.10.77", 6379);
            config.DefaultDatabase = 0;
            config.Password = "123456";
            var connection = ConnectionMultiplexer.Connect(config);
            RedisService.RedisFactory.RegRegisterDefaultRedis(new StackExchangeImpl.Database(connection.GetDatabase()));

        }

    }
}
